package com.atguigu.pojo;

import java.util.Objects;

public class TomcatAndHeartbeatServiceConfig {
    String id;
    String serverId;
    String serviceId;
    String tomcatHome;
    String javaHome;
    String maxMemory;
    String httpPort;
    String shutdownPort;
    String projectId;
    String moduleId;
    String use;
    String heartbeat;

    public TomcatAndHeartbeatServiceConfig() {
    }

    public TomcatAndHeartbeatServiceConfig(String id, String serverId, String serviceId, String tomcatHome, String javaHome, String maxMemory, String httpPort, String shutdownPort, String projectId, String moduleId, String use, String heartbeat) {
        this.id = id;
        this.serverId = serverId;
        this.serviceId = serviceId;
        this.tomcatHome = tomcatHome;
        this.javaHome = javaHome;
        this.maxMemory = maxMemory;
        this.httpPort = httpPort;
        this.shutdownPort = shutdownPort;
        this.projectId = projectId;
        this.moduleId = moduleId;
        this.use = use;
        this.heartbeat = heartbeat;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getServerId() {
        return serverId;
    }

    public void setServerId(String serverId) {
        this.serverId = serverId;
    }

    public String getServiceId() {
        return serviceId;
    }

    public void setServiceId(String serviceId) {
        this.serviceId = serviceId;
    }

    public String getTomcatHome() {
        return tomcatHome;
    }

    public void setTomcatHome(String tomcatHome) {
        this.tomcatHome = tomcatHome;
    }

    public String getJavaHome() {
        return javaHome;
    }

    public void setJavaHome(String javaHome) {
        this.javaHome = javaHome;
    }

    public String getMaxMemory() {
        return maxMemory;
    }

    public void setMaxMemory(String maxMemory) {
        this.maxMemory = maxMemory;
    }

    public String getHttpPort() {
        return httpPort;
    }

    public void setHttpPort(String httpPort) {
        this.httpPort = httpPort;
    }

    public String getShutdownPort() {
        return shutdownPort;
    }

    public void setShutdownPort(String shutdownPort) {
        this.shutdownPort = shutdownPort;
    }

    public String getProjectId() {
        return projectId;
    }

    public void setProjectId(String projectId) {
        this.projectId = projectId;
    }

    public String getModuleId() {
        return moduleId;
    }

    public void setModuleId(String moduleId) {
        this.moduleId = moduleId;
    }

    public String getUse() {
        return use;
    }

    public void setUse(String use) {
        this.use = use;
    }

    public String getHeartbeat() {
        return heartbeat;
    }

    public void setHeartbeat(String heartbeat) {
        this.heartbeat = heartbeat;
    }

    @Override
    public String toString() {
        return "TomcatServiceConfig{" +
                "id='" + id + '\'' +
                ", serverId='" + serverId + '\'' +
                ", serviceId='" + serviceId + '\'' +
                ", tomcatHome='" + tomcatHome + '\'' +
                ", javaHome='" + javaHome + '\'' +
                ", maxMemory='" + maxMemory + '\'' +
                ", httpPort='" + httpPort + '\'' +
                ", shutdownPort='" + shutdownPort + '\'' +
                ", projectId='" + projectId + '\'' +
                ", moduleId='" + moduleId + '\'' +
                ", use='" + use + '\'' +
                ", heartbeat='" + heartbeat + '\'' +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof TomcatAndHeartbeatServiceConfig)) return false;
        TomcatAndHeartbeatServiceConfig that = (TomcatAndHeartbeatServiceConfig) o;
        return getId().equals(that.getId()) &&
                getServerId().equals(that.getServerId()) &&
                getServiceId().equals(that.getServiceId()) &&
                getTomcatHome().equals(that.getTomcatHome()) &&
                getJavaHome().equals(that.getJavaHome()) &&
                getMaxMemory().equals(that.getMaxMemory()) &&
                getHttpPort().equals(that.getHttpPort()) &&
                getShutdownPort().equals(that.getShutdownPort()) &&
                getProjectId().equals(that.getProjectId()) &&
                getModuleId().equals(that.getModuleId()) &&
                getUse().equals(that.getUse()) &&
                getHeartbeat().equals(that.getHeartbeat());
    }

    @Override
    public int hashCode() {
        return Objects.hash(getId(), getServerId(), getServiceId(), getTomcatHome(), getJavaHome(), getMaxMemory(), getHttpPort(), getShutdownPort(), getProjectId(), getModuleId(), getUse(), getHeartbeat());
    }
}
